//
//  UploadCenterViewController.m
//  Rail
//
//  Created by hychen on 2018/2/25.
//  Copyright © 2018年 Hychen. All rights reserved.
//

#import "UploadCenterViewController.h"
#import "UploadSettingViewController.h"

#import "UploadCenterCell.h"

@interface UploadCenterViewController ()

@end

@implementation UploadCenterViewController

- (void)viewDidLoad {
    [super viewDidLoad];

#warning 逻辑
    
    self.tableView.backgroundColor = self.view.backgroundColor;
    
    [self.navigationItem addSimpleTitleView:@"上传中心"];
    
    [self.navigationItem addRightNavItem:self title:@"上传设置" selector:@selector(rightItemClick)];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (void)rightItemClick
{
    //跳转上传设置
    UploadSettingViewController *setVc = [UploadSettingViewController new];
    setVc.hidesBottomBarWhenPushed = YES;
    [[UINavigationController rootNavigationController] pushViewController:setVc animated:YES];
}

#pragma mark - 数据源方法
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
    return 3;
//    return self.dataArray.count;
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    UploadCenterCell *cell = [UploadCenterCell cellWithTableView:tableView class:[UploadCenterCell class]];
    
    return cell;
}

- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
    return 70.f;
}

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
    [tableView deselectRowAtIndexPath:indexPath animated:YES];
}
@end
